package com.yeepay.challenge.game2048.chenpeng;

import com.yeepay.challenge.game2048.GameConsole;

public class Client {

	public static int depth = 5;//search depth

	public static void main(String[] args) {
		double t_start = System.currentTimeMillis() / 1000.0;
		
		int size = 100;
		int sum = 0;
		int max = 0;
		for (int i = 0; i < size; i++) {
			System.out.println("\n第" + (i + 1) + "次，↓");
			long temp = GameConsole.start(PlayerImpl.class);
			if (temp > max) {
				max = (int) temp;
			}
			System.out.println("分数：" + temp + "。 ↑");
			sum += temp;
		}
		double t_end = System.currentTimeMillis() / 1000.0;
		System.out.println("共执行" + size + "次，" + "平均分" + sum / size + ".最大分数为"
				+ max);
		System.out.println("总计耗时：" + (t_end - t_start) + "s");
		System.out.println("平均耗时：" + (t_end - t_start) / 100 + "s");
	}
}
